package com.foxit.setting;
import java.io.Serializable;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.TimeZone;
public class Adana implements Serializable {
     private static final long serialVersionUID = 1L;
     private String start;
     private String id;
     private String grp;
     private String log;
     private String expr;
     private String count;
     private String modify_time;

    public Adana() {
         super();
    }
    public Adana(String start, String id,String grp,String log,String expr,String count,String modify_time) {
         super();
         this.start = start;
         this.id = id;
         this.grp = grp;
         this.log = log;
         this.expr = expr;
         this.count = count;
         this.modify_time = modify_time;
    }
    public String getStart() {
        return start;
        //JSONObject json = JSON.parseObject(start);
        //String d = json.getString("$date");
        //d = d.replace('T',' ');
        //d=d.replace("00.000Z","00");
        //return d;
    }
    public void setStart(String start) {
        this.start = start;
    }
    public String getId() {
        return id;
    }
     public void setId(String id) {
        this.id = id;
    }
    public String getGrp() {
        return grp;
    }
     public void setGrp(String grp) {
        this.grp = grp;
    }
    public String getLog() {
        return log;
    }
     public void setLog(String log) {
        this.log = log;
    }
    public String getExpr() {
        return expr;
    }
    public void setExpr(String expr) {
        this.expr = expr;
    }
    public String getCount() {
        return count;
    }
    public void setCount(String count) {
        this.count = count;
    }
    public String getModify_time() {
        JSONObject json = JSON.parseObject(modify_time);
        String d = json.getString("$date");
        d = d.replace('T',' ');
        //d=d.replace("00.000Z","00");
        return d;
        //return modify_time;
    }
    public long getModify_unixtime() {
        JSONObject json = JSON.parseObject(modify_time);
        String d = json.getString("$date");
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS'Z'");
        long unixtime=0;
        try {
           unixtime = sdf.parse(d).getTime();
        } catch(ParseException e)
        {
           e.printStackTrace();
        }
        return unixtime;
    }
     public void setModify_time(String modify_time) {
        this.modify_time = modify_time;
    }
}
